package com.project.smms.pojo;

import org.springframework.format.annotation.DateTimeFormat;

import java.util.Date;

/**
 * @author 莫息涛
 * @Description: 订单的实体类
 * @date 2020/3/5 16:08
 */
public class Order {

    /**
     * 订单id
     */
    private int order_id;

    /**
     * 订单名称
     */
    private String order_name;

    /**
     * 订单日期
     */
    @DateTimeFormat(pattern="yyyy-MM-dd")
    private Date order_date;

    /**
     * 订单的用户id
     */
    private int order_userid;

    public Order() {
    }

    public Order(int order_id, String order_name, Date order_date, int order_userid) {
        this.order_id = order_id;
        this.order_name = order_name;
        this.order_date = order_date;
        this.order_userid = order_userid;
    }

    public int getOrder_id() {
        return order_id;
    }

    public void setOrder_id(int order_id) {
        this.order_id = order_id;
    }

    public String getOrder_name() {
        return order_name;
    }

    public void setOrder_name(String order_name) {
        this.order_name = order_name;
    }

    public Date getOrder_date() {
        return order_date;
    }

    public void setOrder_date(Date order_date) {
        this.order_date = order_date;
    }

    public int getOrder_userid() {
        return order_userid;
    }

    public void setOrder_userid(int order_userid) {
        this.order_userid = order_userid;
    }

    @Override
    public String toString() {
        return "Order{" +
                "order_id=" + order_id +
                ", order_name='" + order_name + '\'' +
                ", order_date=" + order_date +
                ", order_userid=" + order_userid +
                '}';
    }
}
